<<<<<<< .mine
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.8"/>
<title>prngd: BBS Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">prngd
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.8 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('class_b_b_s.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="class_b_b_s-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">BBS Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Blum Blum Shub pseudo random number generator.  
 <a href="class_b_b_s.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_b_b_s_8h_source.html">BBS.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:af74a83220f1c159b5e781d9272aac6af"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#af74a83220f1c159b5e781d9272aac6af">BBS</a> ()</td></tr>
<tr class="separator:af74a83220f1c159b5e781d9272aac6af"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a29a4e6f7e46aa8b41f777b4674a1b2f0">~BBS</a> ()</td></tr>
<tr class="separator:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a698e05fd2f2968af4600fb160e7faeb7"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7">generateBits</a> (mpz_t s, int bitCount)</td></tr>
<tr class="separator:a698e05fd2f2968af4600fb160e7faeb7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:a0659bff6844aaba740d202b8ca168ae1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1">create_M</a> (int bitCount)</td></tr>
<tr class="separator:a0659bff6844aaba740d202b8ca168ae1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0ed9e0716b956c8a6cf4bba451bf1d0a">printRndData</a> (char *data, int size, bool binary)</td></tr>
<tr class="separator:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adadf22f67593a49c880d4f0a22ef83dd"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd">getBlumPrime</a> (mpz_t bigInt, int bits)</td></tr>
<tr class="separator:adadf22f67593a49c880d4f0a22ef83dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:afb322d716709aadc84757afb175e8b4d"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#afb322d716709aadc84757afb175e8b4d">p</a></td></tr>
<tr class="separator:afb322d716709aadc84757afb175e8b4d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5f87feb08e663a273fcd0c4e2d9f9783">q</a></td></tr>
<tr class="separator:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#ae25fb37464f6b72594ee0ff42b0efec9">m</a></td></tr>
<tr class="separator:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa60e8fbdacc92d5b4becfec3bce311cf">r</a></td></tr>
<tr class="separator:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa783fdd72784f429a1a6cf7fff220c56"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa783fdd72784f429a1a6cf7fff220c56">output</a></td></tr>
<tr class="separator:aa783fdd72784f429a1a6cf7fff220c56"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a95a4c72abceacc420fd2b46e34ad9cad">output2</a></td></tr>
<tr class="separator:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5922b1da44459a23aaed78f69fd6d1a1">byteOutput</a></td></tr>
<tr class="separator:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a6276b1cee047bd66aa6a64517a3e2e31">useRandom</a></td></tr>
<tr class="separator:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Blum Blum Shub pseudo random number generator. </p>
<p>This class implements the Blum Blum Shub (bbs) prngd to create random bits. For big integer computation, the gnu gmp library is used. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="af74a83220f1c159b5e781d9272aac6af"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Constructor </p>

</div>
</div>
<a class="anchor" id="a29a4e6f7e46aa8b41f777b4674a1b2f0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::~BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Destructor </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a0659bff6844aaba740d202b8ca168ae1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::create_M </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generates the modul m (p*q) which is a private variable. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bitCount</td><td>The number of needed random bits. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="164,5,303,32"/><area shape="rect" id="node3" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="351,5,483,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="164,107,295,133"/><area shape="rect" id="node3" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="343,107,433,133"/><area shape="rect" id="node4" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="483,5,647,32"/><area shape="rect" id="node5" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="498,56,631,83"/><area shape="rect" id="node6" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="483,107,647,133"/><area shape="rect" id="node7" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="481,157,648,184"/><area shape="rect" id="node8" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="481,208,648,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a698e05fd2f2968af4600fb160e7faeb7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char * BBS::generateBits </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>s</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Generates a number of random bits. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">s</td><td>A initial big integer seed for bbs. </td></tr>
    <tr><td class="paramname">bitCount</td><td>The number of bits to generate. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The generated random bits as char-array. </dd></dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="184,5,295,32"/><area shape="rect" id="node3" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="343,5,481,32"/><area shape="rect" id="node4" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="529,5,661,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph">
<area shape="rect" id="node2" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="184,107,275,133"/><area shape="rect" id="node3" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="324,5,488,32"/><area shape="rect" id="node4" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="339,56,473,83"/><area shape="rect" id="node5" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="324,107,488,133"/><area shape="rect" id="node6" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="323,157,489,184"/><area shape="rect" id="node7" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="323,208,489,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adadf22f67593a49c880d4f0a22ef83dd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::getBlumPrime </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>bigInt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bits</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generate a blum prime ( 4k+3 ) </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bigInt</td><td>A big integer variable to save the generated blum prime. </td></tr>
    <tr><td class="paramname">bits</td><td>Size in bits for the blum prime. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph">
<area shape="rect" id="node2" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="192,5,324,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="192,107,303,133"/><area shape="rect" id="node3" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="351,107,481,133"/><area shape="rect" id="node4" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="529,107,620,133"/><area shape="rect" id="node5" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="669,5,833,32"/><area shape="rect" id="node6" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="685,56,818,83"/><area shape="rect" id="node7" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="669,107,833,133"/><area shape="rect" id="node8" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="668,157,835,184"/><area shape="rect" id="node9" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="668,208,835,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a0ed9e0716b956c8a6cf4bba451bf1d0a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::printRndData </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>binary</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Helpfunction for debugging which prints a char-array of to std::out. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">data</td><td>Pointer to the data which has to be printed. </td></tr>
    <tr><td class="paramname">size</td><td>Size of the data(-array). </td></tr>
    <tr><td class="paramname">binary</td><td>If true, every character of the data will be printed as 8 chars of ones and zeros. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a class="anchor" id="a5922b1da44459a23aaed78f69fd6d1a1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">char* BBS::byteOutput</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Contains the random bits of output2 as char-array (8bit per char) and is given back as return value </p>

</div>
</div>
<a class="anchor" id="ae25fb37464f6b72594ee0ff42b0efec9"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::m</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>The modul M (= p * q) </p>

</div>
</div>
<a class="anchor" id="aa783fdd72784f429a1a6cf7fff220c56"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a95a4c72abceacc420fd2b46e34ad9cad"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output2</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Final var which contains all the generated rando bits of the bbs </p>

</div>
</div>
<a class="anchor" id="afb322d716709aadc84757afb175e8b4d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::p</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>First blumprime (3mod4) which is part of m </p>

</div>
</div>
<a class="anchor" id="a5f87feb08e663a273fcd0c4e2d9f9783"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::q</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Second blumprime (3mod4) whis is part of m </p>

</div>
</div>
<a class="anchor" id="aa60e8fbdacc92d5b4becfec3bce311cf"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::r</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a6276b1cee047bd66aa6a64517a3e2e31"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool BBS::useRandom</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>If this is true, the generator will TRY to use /dev/random </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>H:/prngd_server/inc/<a class="el" href="_b_b_s_8h_source.html">BBS.h</a></li>
<li>H:/prngd_server/src/BBS.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="class_b_b_s.html">BBS</a></li>
    <li class="footer">Generated on Fri Aug 29 2014 14:14:52 for prngd by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.8 </li>
  </ul>
</div>
</body>
</html>
=======
<<<<<<< .mine
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.8"/>
<title>prngd: BBS Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">prngd
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.8 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('class_b_b_s.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="class_b_b_s-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">BBS Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Blum Blum Shub pseudo random number generator.  
 <a href="class_b_b_s.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_b_b_s_8h_source.html">BBS.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:af74a83220f1c159b5e781d9272aac6af"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#af74a83220f1c159b5e781d9272aac6af">BBS</a> ()</td></tr>
<tr class="separator:af74a83220f1c159b5e781d9272aac6af"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a29a4e6f7e46aa8b41f777b4674a1b2f0">~BBS</a> ()</td></tr>
<tr class="separator:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a698e05fd2f2968af4600fb160e7faeb7"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7">generateBits</a> (mpz_t s, int bitCount)</td></tr>
<tr class="separator:a698e05fd2f2968af4600fb160e7faeb7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:a0659bff6844aaba740d202b8ca168ae1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1">create_M</a> (int bitCount)</td></tr>
<tr class="separator:a0659bff6844aaba740d202b8ca168ae1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0ed9e0716b956c8a6cf4bba451bf1d0a">printRndData</a> (char *data, int size, bool binary)</td></tr>
<tr class="separator:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adadf22f67593a49c880d4f0a22ef83dd"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd">getBlumPrime</a> (mpz_t bigInt, int bits)</td></tr>
<tr class="separator:adadf22f67593a49c880d4f0a22ef83dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:afb322d716709aadc84757afb175e8b4d"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#afb322d716709aadc84757afb175e8b4d">p</a></td></tr>
<tr class="separator:afb322d716709aadc84757afb175e8b4d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5f87feb08e663a273fcd0c4e2d9f9783">q</a></td></tr>
<tr class="separator:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#ae25fb37464f6b72594ee0ff42b0efec9">m</a></td></tr>
<tr class="separator:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa60e8fbdacc92d5b4becfec3bce311cf">r</a></td></tr>
<tr class="separator:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa783fdd72784f429a1a6cf7fff220c56"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa783fdd72784f429a1a6cf7fff220c56">output</a></td></tr>
<tr class="separator:aa783fdd72784f429a1a6cf7fff220c56"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a95a4c72abceacc420fd2b46e34ad9cad">output2</a></td></tr>
<tr class="separator:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5922b1da44459a23aaed78f69fd6d1a1">byteOutput</a></td></tr>
<tr class="separator:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a6276b1cee047bd66aa6a64517a3e2e31">useRandom</a></td></tr>
<tr class="separator:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Blum Blum Shub pseudo random number generator. </p>
<p>This class implements the Blum Blum Shub (bbs) prngd to create random bits. For big integer computation, the gnu gmp library is used. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="af74a83220f1c159b5e781d9272aac6af"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Constructor </p>

</div>
</div>
<a class="anchor" id="a29a4e6f7e46aa8b41f777b4674a1b2f0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::~BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Destructor </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a0659bff6844aaba740d202b8ca168ae1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::create_M </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generates the modul m (p*q) which is a private variable. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bitCount</td><td>The number of needed random bits. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="164,5,303,32"/><area shape="rect" id="node3" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="351,5,483,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="164,107,295,133"/><area shape="rect" id="node3" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="343,107,433,133"/><area shape="rect" id="node4" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="483,5,647,32"/><area shape="rect" id="node5" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="498,56,631,83"/><area shape="rect" id="node6" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="483,107,647,133"/><area shape="rect" id="node7" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="481,157,648,184"/><area shape="rect" id="node8" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="481,208,648,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a698e05fd2f2968af4600fb160e7faeb7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char * BBS::generateBits </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>s</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Generates a number of random bits. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">s</td><td>A initial big integer seed for bbs. </td></tr>
    <tr><td class="paramname">bitCount</td><td>The number of bits to generate. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The generated random bits as char-array. </dd></dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="184,5,295,32"/><area shape="rect" id="node3" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="343,5,481,32"/><area shape="rect" id="node4" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="529,5,661,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph">
<area shape="rect" id="node2" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="184,107,275,133"/><area shape="rect" id="node3" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="324,5,488,32"/><area shape="rect" id="node4" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="339,56,473,83"/><area shape="rect" id="node5" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="324,107,488,133"/><area shape="rect" id="node6" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="323,157,489,184"/><area shape="rect" id="node7" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="323,208,489,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adadf22f67593a49c880d4f0a22ef83dd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::getBlumPrime </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>bigInt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bits</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generate a blum prime ( 4k+3 ) </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bigInt</td><td>A big integer variable to save the generated blum prime. </td></tr>
    <tr><td class="paramname">bits</td><td>Size in bits for the blum prime. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph">
<area shape="rect" id="node2" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="192,5,324,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="192,107,303,133"/><area shape="rect" id="node3" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="351,107,481,133"/><area shape="rect" id="node4" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="529,107,620,133"/><area shape="rect" id="node5" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="669,5,833,32"/><area shape="rect" id="node6" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="685,56,818,83"/><area shape="rect" id="node7" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="669,107,833,133"/><area shape="rect" id="node8" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="668,157,835,184"/><area shape="rect" id="node9" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="668,208,835,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a0ed9e0716b956c8a6cf4bba451bf1d0a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::printRndData </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>binary</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Helpfunction for debugging which prints a char-array of to std::out. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">data</td><td>Pointer to the data which has to be printed. </td></tr>
    <tr><td class="paramname">size</td><td>Size of the data(-array). </td></tr>
    <tr><td class="paramname">binary</td><td>If true, every character of the data will be printed as 8 chars of ones and zeros. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a class="anchor" id="a5922b1da44459a23aaed78f69fd6d1a1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">char* BBS::byteOutput</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Contains the random bits of output2 as char-array (8bit per char) and is given back as return value </p>

</div>
</div>
<a class="anchor" id="ae25fb37464f6b72594ee0ff42b0efec9"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::m</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>The modul M (= p * q) </p>

</div>
</div>
<a class="anchor" id="aa783fdd72784f429a1a6cf7fff220c56"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a95a4c72abceacc420fd2b46e34ad9cad"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output2</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Final var which contains all the generated rando bits of the bbs </p>

</div>
</div>
<a class="anchor" id="afb322d716709aadc84757afb175e8b4d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::p</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>First blumprime (3mod4) which is part of m </p>

</div>
</div>
<a class="anchor" id="a5f87feb08e663a273fcd0c4e2d9f9783"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::q</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Second blumprime (3mod4) whis is part of m </p>

</div>
</div>
<a class="anchor" id="aa60e8fbdacc92d5b4becfec3bce311cf"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::r</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a6276b1cee047bd66aa6a64517a3e2e31"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool BBS::useRandom</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>If this is true, the generator will TRY to use /dev/random </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>H:/prngd_server/inc/<a class="el" href="_b_b_s_8h_source.html">BBS.h</a></li>
<li>H:/prngd_server/src/BBS.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="class_b_b_s.html">BBS</a></li>
    <li class="footer">Generated on Fri Aug 29 2014 14:14:52 for prngd by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.8 </li>
  </ul>
</div>
</body>
</html>
=======
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.8"/>
<title>prngd: BBS Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">prngd
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.8 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('class_b_b_s.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="class_b_b_s-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">BBS Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Blum Blum Shub pseudo random number generator.  
 <a href="class_b_b_s.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_b_b_s_8h_source.html">BBS.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:af74a83220f1c159b5e781d9272aac6af"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#af74a83220f1c159b5e781d9272aac6af">BBS</a> ()</td></tr>
<tr class="separator:af74a83220f1c159b5e781d9272aac6af"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a29a4e6f7e46aa8b41f777b4674a1b2f0">~BBS</a> ()</td></tr>
<tr class="separator:a29a4e6f7e46aa8b41f777b4674a1b2f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a698e05fd2f2968af4600fb160e7faeb7"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7">generateBits</a> (mpz_t s, int bitCount)</td></tr>
<tr class="separator:a698e05fd2f2968af4600fb160e7faeb7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:a0659bff6844aaba740d202b8ca168ae1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1">create_M</a> (int bitCount)</td></tr>
<tr class="separator:a0659bff6844aaba740d202b8ca168ae1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a0ed9e0716b956c8a6cf4bba451bf1d0a">printRndData</a> (char *data, int size, bool binary)</td></tr>
<tr class="separator:a0ed9e0716b956c8a6cf4bba451bf1d0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adadf22f67593a49c880d4f0a22ef83dd"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd">getBlumPrime</a> (mpz_t bigInt, int bits)</td></tr>
<tr class="separator:adadf22f67593a49c880d4f0a22ef83dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:afb322d716709aadc84757afb175e8b4d"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#afb322d716709aadc84757afb175e8b4d">p</a></td></tr>
<tr class="separator:afb322d716709aadc84757afb175e8b4d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5f87feb08e663a273fcd0c4e2d9f9783">q</a></td></tr>
<tr class="separator:a5f87feb08e663a273fcd0c4e2d9f9783"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#ae25fb37464f6b72594ee0ff42b0efec9">m</a></td></tr>
<tr class="separator:ae25fb37464f6b72594ee0ff42b0efec9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa60e8fbdacc92d5b4becfec3bce311cf">r</a></td></tr>
<tr class="separator:aa60e8fbdacc92d5b4becfec3bce311cf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa783fdd72784f429a1a6cf7fff220c56"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#aa783fdd72784f429a1a6cf7fff220c56">output</a></td></tr>
<tr class="separator:aa783fdd72784f429a1a6cf7fff220c56"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memItemLeft" align="right" valign="top">mpz_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a95a4c72abceacc420fd2b46e34ad9cad">output2</a></td></tr>
<tr class="separator:a95a4c72abceacc420fd2b46e34ad9cad"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a5922b1da44459a23aaed78f69fd6d1a1">byteOutput</a></td></tr>
<tr class="separator:a5922b1da44459a23aaed78f69fd6d1a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_b_b_s.html#a6276b1cee047bd66aa6a64517a3e2e31">useRandom</a></td></tr>
<tr class="separator:a6276b1cee047bd66aa6a64517a3e2e31"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Blum Blum Shub pseudo random number generator. </p>
<p>This class implements the Blum Blum Shub (bbs) prngd to create random bits. For big integer computation, the gnu gmp library is used. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="af74a83220f1c159b5e781d9272aac6af"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Constructor </p>

</div>
</div>
<a class="anchor" id="a29a4e6f7e46aa8b41f777b4674a1b2f0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">BBS::~BBS </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Destructor </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a0659bff6844aaba740d202b8ca168ae1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::create_M </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generates the modul m (p*q) which is a private variable. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bitCount</td><td>The number of needed random bits. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="164,5,303,32"/><area shape="rect" id="node3" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="351,5,483,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph.png" border="0" usemap="#class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" alt=""/></div>
<map name="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph" id="class_b_b_s_a0659bff6844aaba740d202b8ca168ae1_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="164,107,295,133"/><area shape="rect" id="node3" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="343,107,433,133"/><area shape="rect" id="node4" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="483,5,647,32"/><area shape="rect" id="node5" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="498,56,631,83"/><area shape="rect" id="node6" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="483,107,647,133"/><area shape="rect" id="node7" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="481,157,648,184"/><area shape="rect" id="node8" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="481,208,648,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a698e05fd2f2968af4600fb160e7faeb7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char * BBS::generateBits </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>s</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bitCount</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Generates a number of random bits. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">s</td><td>A initial big integer seed for bbs. </td></tr>
    <tr><td class="paramname">bitCount</td><td>The number of bits to generate. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The generated random bits as char-array. </dd></dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_cgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="184,5,295,32"/><area shape="rect" id="node3" href="class_b_b_s.html#adadf22f67593a49c880d4f0a22ef83dd" title="BBS::getBlumPrime" alt="" coords="343,5,481,32"/><area shape="rect" id="node4" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="529,5,661,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph.png" border="0" usemap="#class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" alt=""/></div>
<map name="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph" id="class_b_b_s_a698e05fd2f2968af4600fb160e7faeb7_icgraph">
<area shape="rect" id="node2" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="184,107,275,133"/><area shape="rect" id="node3" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="324,5,488,32"/><area shape="rect" id="node4" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="339,56,473,83"/><area shape="rect" id="node5" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="324,107,488,133"/><area shape="rect" id="node6" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="323,157,489,184"/><area shape="rect" id="node7" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="323,208,489,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adadf22f67593a49c880d4f0a22ef83dd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::getBlumPrime </td>
          <td>(</td>
          <td class="paramtype">mpz_t&#160;</td>
          <td class="paramname"><em>bigInt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>bits</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Generate a blum prime ( 4k+3 ) </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bigInt</td><td>A big integer variable to save the generated blum prime. </td></tr>
    <tr><td class="paramname">bits</td><td>Size in bits for the blum prime. </td></tr>
  </table>
  </dd>
</dl>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_cgraph">
<area shape="rect" id="node2" href="class_prngd.html#a9e5848669332f0936a77b2db0c663c37" title="Prngd::getRndData" alt="" coords="192,5,324,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph.png" border="0" usemap="#class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" alt=""/></div>
<map name="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph" id="class_b_b_s_adadf22f67593a49c880d4f0a22ef83dd_icgraph">
<area shape="rect" id="node2" href="class_b_b_s.html#a0659bff6844aaba740d202b8ca168ae1" title="BBS::create_M" alt="" coords="192,107,303,133"/><area shape="rect" id="node3" href="class_b_b_s.html#a698e05fd2f2968af4600fb160e7faeb7" title="BBS::generateBits" alt="" coords="351,107,481,133"/><area shape="rect" id="node4" href="class_prngd.html#a617fbe2be79677859235262d59b4c0f0" title="Prngd::work" alt="" coords="529,107,620,133"/><area shape="rect" id="node5" href="class_m_q___server.html#a1b5ef576c33539eea304bb7d2ddf15fe" title="MQ_Server::thread_work" alt="" coords="669,5,833,32"/><area shape="rect" id="node6" href="class_prngd___server.html#ad4f2bc38081117e23a1c385ff1dd5e0b" title="Prngd_Server::start" alt="" coords="685,56,818,83"/><area shape="rect" id="node7" href="class_tcp___server.html#a2edda05badb8d3b7838679aaaa70b470" title="Tcp_Server::thread_work" alt="" coords="669,107,833,133"/><area shape="rect" id="node8" href="class_udp___server.html#a1fb86c8c08d020a4e2262cf557e4b78d" title="Udp_Server::thread_work" alt="" coords="668,157,835,184"/><area shape="rect" id="node9" href="class_uds___server.html#a8b68567d116ebb1db824e3039507331d" title="Uds_Server::thread_work" alt="" coords="668,208,835,235"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a0ed9e0716b956c8a6cf4bba451bf1d0a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void BBS::printRndData </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>binary</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Helpfunction for debugging which prints a char-array of to std::out. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">data</td><td>Pointer to the data which has to be printed. </td></tr>
    <tr><td class="paramname">size</td><td>Size of the data(-array). </td></tr>
    <tr><td class="paramname">binary</td><td>If true, every character of the data will be printed as 8 chars of ones and zeros. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a class="anchor" id="a5922b1da44459a23aaed78f69fd6d1a1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">char* BBS::byteOutput</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Contains the random bits of output2 as char-array (8bit per char) and is given back as return value </p>

</div>
</div>
<a class="anchor" id="ae25fb37464f6b72594ee0ff42b0efec9"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::m</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>The modul M (= p * q) </p>

</div>
</div>
<a class="anchor" id="aa783fdd72784f429a1a6cf7fff220c56"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a95a4c72abceacc420fd2b46e34ad9cad"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::output2</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Final var which contains all the generated rando bits of the bbs </p>

</div>
</div>
<a class="anchor" id="afb322d716709aadc84757afb175e8b4d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::p</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>First blumprime (3mod4) which is part of m </p>

</div>
</div>
<a class="anchor" id="a5f87feb08e663a273fcd0c4e2d9f9783"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::q</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Second blumprime (3mod4) whis is part of m </p>

</div>
</div>
<a class="anchor" id="aa60e8fbdacc92d5b4becfec3bce311cf"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">mpz_t BBS::r</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Temp var for intern computations </p>

</div>
</div>
<a class="anchor" id="a6276b1cee047bd66aa6a64517a3e2e31"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool BBS::useRandom</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>If this is true, the generator will TRY to use /dev/random </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>H:/prngd_server/inc/<a class="el" href="_b_b_s_8h_source.html">BBS.h</a></li>
<li>H:/prngd_server/src/BBS.cpp</li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="class_b_b_s.html">BBS</a></li>
    <li class="footer">Generated on Sun Aug 31 2014 18:01:31 for prngd by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.8 </li>
  </ul>
</div>
</body>
</html>
>>>>>>> .r39
>>>>>>> .r46
